{* include file="tpl_defaults/header.html" *}

    <div id="main">

        <!-- 面包屑导航 -->
        <div id="bread" class="box list sky-blue">
            <span class="left">
                <a href="{*$app_bbs_url*}">爱居社区</a>
				{* foreach from=$aMenuForum  key = key item=item *}
				{*if $item->fid eq $fid*}
				   <img src="/images/divider.gif" /> <a href="list.php?fid={*$item->fid*}">{*$item->name*}</a>
				{*else*}
				   <img src="/images/divider.gif" /> {*$item->name*}
				{*/if*}
				{*/foreach*}
            </span>
        </div>

        <!-- 发布新帖子 -->
        <div class="list">
            <h4 class="block_sub">回复帖子：{*$opost->subject*}</h4>
            <div class="post_table mainbox">
                <form id="form1" name="form1" method="post" action="reply.php?action=do" enctype="multipart/form-data" >
                <table>
                    <tbody>
                        <tr>
                            <td class="npostl">标题</td>
                            <td class="npostr">
                                <input class="npost-subject txt" type="text" name="subject" value="回复：{*$opost->subject*}">
                                <em>(必填)</em>
                            </td>
                        </tr>
                    </tbody>
                    <tbody>
                        <tr>
                            <td class="npostl">主题图标</td>
                            <td class="npostr">
                                <ul class="npost-icon">
                                    <li> <input type="radio" name="icon" value="" checked> <img src="/images/icon/1.gif"></li>
                                    <li><input type="radio" name="icon" value="2.gif"> <img src="/images/icon/2.gif"></li>
                                    <li><input type="radio" name="icon" value="3.gif"> <img src="/images/icon/3.gif"></li>
                                    <li><input type="radio" name="icon" value="4.gif"> <img src="/images/icon/4.gif"></li>
                                    <li><input type="radio" name="icon" value="5.gif"> <img src="/images/icon/5.gif"></li>
                                    <li><input type="radio" name="icon" value="6.gif"> <img src="/images/icon/6.gif"></li>
                                    <li><input type="radio" name="icon" value="7.gif"> <img src="/images/icon/7.gif"></li>
                                    <li><input type="radio" name="icon" value="8.gif"> <img src="/images/icon/8.gif"></li>
                                    <li><input type="radio" name="icon" value="9.gif"> <img src="/images/icon/9.gif"></li>
                                    <li><input type="radio" name="icon" value="10.gif"> <img src="/images/icon/10.gif"></li>
                                    <li><input type="radio" name="icon" value="11.gif"> <img src="/images/icon/11.gif"></li>
                                    <li><input type="radio" name="icon" value="12.gif"> <img src="/images/icon/12.gif"></li>
                                    <li><input type="radio" name="icon" value="13.gif"> <img src="/images/icon/13.gif"></li>
                                    <li><input type="radio" name="icon" value="14.gif"> <img src="/images/icon/14.gif"></li>
                                </ul>
                            </td>
                        </tr>
                    </tbody>
                    <tbody>
                        <tr>
                            <td class="npostl">
                                <fieldset class="postrules">
                                    <legend>选项</legend>
                                    <dl>
                                        <dd><input type="checkbox" name="allowubbcode" value="Y" {*if $oGroup->allowubbcode eq 'N'*}disabled{*/if*} checked />使用CTB代码</dd>
                                        <dd><input type="checkbox" name="allowhtml" value="Y" {*if $oGroup->allowhtml eq 'N'*}disabled{*/if*} />使用HTML代码</dd>
                                        <dd><input type="checkbox" name="allowsmiley" value="Y" checked />使用图片解析</dd>
                                        <dd><input type="checkbox" name="allowparseurl" value="Y" checked />使用URL解析</dd>
                                        <dd><input type="checkbox" name="usesig" value="Y" {*if $oGroup->allowsig eq 'N'*}disabled{*/if*} />使用我的签名</dd>
                                        <dd><input type="checkbox" name="isanonymous" value="Y" {*if $oGroup->allowanonymous eq 'N'*}disabled{*/if*} />使用匿名发帖</dd>
                                    </dl>
                                </fieldset>
                            </td>
                            <td class="npostr">
                                <div class="npost-txtarea">
<style type="text/css">
<!--
.btnCode {
	background:transparent url({*$sys_scripts_url*}xheditor/syntaxhighlighter/code.gif) no-repeat 16px 16px;
	background-position:2px 2px;
}
.btnFlv {
	background:transparent url({*$sys_scripts_url*}xheditor/mediaplayer/flv.gif) no-repeat 16px 16px;
	background-position:2px 2px;
}
-->
</style>
<script type="text/javascript" src="{*$sys_scripts_url*}jquery/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="{*$sys_scripts_url*}xheditor/xheditor.min.js?v=1.0.0-final"></script>
<script type="text/javascript" src="{*$sys_scripts_url*}xheditor/xheditor_plugins/ubb.min.js"></script>
<script type="text/javascript">
$(pageInit);
function pageInit()
{
	$('#elm1').xheditor({upImgUrl:"post_upload.php?immediate=1",upImgExt:"jpg,jpeg,gif,png",plugins:{Code:{c:'btnCode',t:'插入代码',h:1,e:function(){
			var _this=this;
			var htmlCode='<div><select id="xheCodeType"><option value="html">HTML/XML</option><option value="javascript">JavaScript</option><option value="css">CSS</option><option value="php">PHP</option><option value="csharp">C#</option><option value="cpp">C++</option><option value="java">Java</option><option value="python">Python</option><option value="ruby">Ruby</option><option value="vb">Visual Basic</option><option value="delphi">Delphi</option><option value="sql">SQL</option><option value="plain">其它</option></select></div><div><textarea id="xheCodeValue" wrap="soft" spellcheck="false" style="width:300px;height:100px;" /></div><div style="text-align:right;"><input type="button" id="xheSave" value="确定" /></div>';			var jCode=$(htmlCode),jType=$('#xheCodeType',jCode),jValue=$('#xheCodeValue',jCode),jSave=$('#xheSave',jCode);
			jSave.click(function(){
				_this.loadBookmark();
				_this.pasteText('[code='+jType.val()+']\r\n'+jValue.val()+'\r\n[/code]');
				_this.hidePanel();
				return false;	
			});
			_this.showDialog(jCode);
		}},Flv:{c:'btnFlv',t:'插入Flv视频',h:1,e:function(){
			var _this=this;
			var htmlFlv='<div>Flv文件:&nbsp; <input type="text" id="xheFlvUrl" value="http://" class="xheText" /></div><div>宽度高度: <input type="text" id="xheFlvWidth" style="width:40px;" value="480" /> x <input type="text" id="xheFlvHeight" style="width:40px;" value="400" /></div><div style="text-align:right;"><input type="button" id="xheSave" value="确定" /></div>';
			var jFlv=$(htmlFlv),jUrl=$('#xheFlvUrl',jFlv),jWidth=$('#xheFlvWidth',jFlv),jHeight=$('#xheFlvHeight',jFlv),jSave=$('#xheSave',jFlv);
			jSave.click(function(){
				_this.loadBookmark();
				_this.pasteText('[flv='+jWidth.val()+','+jHeight.val()+']'+jUrl.val()+'[/flv]');
				_this.hidePanel();
				return false;	
			});
			_this.showDialog(jFlv);
		}}},
		tools:'full',showBlocktag:false,forcePtag:false,beforeSetSource:ubb2html,beforeGetSource:html2ubb,emots:{msn:{name:'MSN',count:40,width:22,height:22,line:8}},emotMark:true,shortcuts:{'ctrl+enter':submitForm}});
}
function submitForm(){$('#frmDemo').submit();}
</script>
                                    <textarea name="elm1" id="elm1" style="height:250px; overflow-y:auto;width: 100%"  rows="12" cols="80" >{*$quoteinfo*}</textarea>
                                </div>
								{*if $oGroup->allowupload eq 'Y'*}
                                <fieldset class="npost-upload fieldset">
                                    <legend>上传附件</legend>
                                    <p>描述<input class="txt" type="text" name="filename[]" size="10">
                                    <input class="upload txt" style="border:1px;" type="file" id="fileup" name="fileup[]" />
                                    <input type="checkbox" name="filereply[]" value="1"/> 隐藏附件(回复可见)
                                    <input type="checkbox" name="fileorder[]" value="credit"/>售<input class="minitxt txt" type="text"  name="filecredit[]" />积分</p>
                                    <p>上传文件必须小于({*$uploadsize*})KB <br />上传允许类型：{*$uploadtype*} </p>
                                </fieldset>
								{*/if*}
                                <div class="npost-submit">
									<input type="hidden" name="fid" value="{*$fid*}">
                                    <input class="submit" type="submit" value="发表主题" />
                                </div>
                                <div class="npost-rules">
                                    <blockquote class="gray">
                                        这里发帖，表示您接受了爱居社区的 用户行为准则。<br />
                                        请您对您的言行负责，并遵守中华人民共和国有关法律、法规,尊重网上道德。
                                    </blockquote>
                                </div>
                            </td>
                        </tr>
                    </tbody>
                </table>
		<input type="hidden" name="fid" value="{*$fid*}">
		<input type="hidden" name="tid" value="{*$tid*}">
                </form>
            </div>
        </div>

    </div>
{* include file="tpl_defaults/footer.html" *}

